<?php

include '../DB/dbConnection.php';

$result=array();

if ($_POST){
	$stmt = $conn->prepare("DELETE FROM teachers WHERE id=?");
	$stmt->bind_param("i",$_POST['id']);
	$success = $stmt->execute();
	$stmt->close();
	$conn->close();
	
	if($success)
		$result['error']='false';
	else
		$result['error']='true';
}
else
{
	$result['error']='true';
}

echo json_encode($result);
?> 
